import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 86183
 * Date: 2024-04-12
 * Time: 9:49
 */
public class Test {
    public static void main(String[] args) {
        Demo3 demo3=new Demo3();
        String[] words={"foo","bar"};
       List<Integer> list = demo3.findSubstring( "barfoothefoobarman",words);
        System.out.println(list);
    }
}
